<script setup>
defineOptions({ name: "Introduction", index: 1 });
import data from "@/assets/data/data.json";
import { ref, onMounted } from "vue";
const isPC = ref(true);
onMounted(() => {
  isPC.value = window.innerWidth > 768;
});
</script>
<template>
  <h1 class="animate__animated animate__slideInLeft">
    {{ data.Home.header[1] }}
  </h1>
  <main>
    <aside>
      <!-- 左侧内容 -->
      <div class="left" v-if="isPC">
        <div class="animate__animated animate__fadeInLeft">
          <img src="@/assets/pictures/Introduaction.jpg" />
        </div>
      </div>
      <!-- 右侧内容 -->
      <div class="right">
        <!-- 公司介绍 -->
        <p class="animate__animated animate__zoomIn">
          {{ data.Itroduction.description }}
        </p>
      </div>
    </aside>
  </main>
</template>

<style scoped lang="less">
h1 {
  font-size: 30px;
  text-align: center;
}
main {
  p {
    font-size: 20px;
    text-align: center;
    margin: 10px;
  }
  aside {
    display: flex;
    .left {
      flex: 1;
      img {
        width: 100%;
        height: 100%;
        padding: 50px;
      }
    }
    .right {
      flex: 1;
      p {
        padding: 30px;
      }
    }
  }
}
</style>
